<%@ page language="java" errorPage="/error.jsp" pageEncoding="UTF-8" contentType="text/html;charset=utf-8" %>
<%@ include file="/common/taglibs.jsp" %>
<head>
    <%@ include file="/common/meta.jsp" %>
    <title>意见反馈</title>
    <link rel="stylesheet" href="${dll}/api/styles/eshowmui.min.css">
    <%--<%@ include file="/common/styles.jsp" %>--%>

</head>
<body ontouchstart>
<form action="#">
    <div class="eui-feedback">
        <div class="eui-form">
            <div class="eui-form-item eui-form-item-pure">
                <input type="text" id="link" placeholder="请输入联系方式">
            </div>
            <div class="eui-form-item eui-form-item-pure">
                <textarea id="comment" placeholder="请输入反馈内容"></textarea>
            </div>
        </div>
        <div class="padding">
            <a href="javascript:;" id="addform" class="eui-btn eui-btn-primary">提交</a>
        </div>
    </div>
</form>

<%--<script src="http://apps.bdimg.com/libs/jquery/2.1.4/jquery.min.js"></script>--%>
<%--<script src="${dll}/api/scripts/EShowmb/EShowmb.min.js"></script>--%>
<%@ include file="/common/scripts.jsp" %>

<script>
    $("#addform").on("click", function () {
        var link = $("#link").val();
        var comment = $("#comment").val();
        if (link.length > 0 && comment.length > 0) {

            $.ajax({
                url: "${ctx}/system!feedback.action",
                data: {
                    content: comment,
                },
                type: "post",
                async: false,
                dataType: "json",
                success: function (result) {
                    EShowmb.msg('提交成功');
                    var _html = '<p class="successtip"><span>您的反馈已经提交成功！</span></p>'
                    $(".eui-feedback").html(_html);
                }
            });

        } else {
            EShowmb.msg('请输入内容');
            return
        }
    })
</script>
</body>